import Vue from "vue";
// import auth from "./modules/auth";
import copy from "./modules/copy";
import call from "./modules/call";
// import waterMarker from "./modules/waterMarker";
// import draggable from "./modules/draggable";
import debounce from "./modules/debounce";
import throttle from "./modules/throttle";
// import longpress from "./modules/longpress";

const directivesList = {
	// Custom directives
	// auth,
	copy,
	call,
	// waterMarker,
	// draggable,
	debounce, // 防抖
	throttle, // 节流
	// longpress
};

const directives = {
	install: (app) => {
		console.log('directivesList', directivesList);
		Object.keys(directivesList).forEach(key => {
			console.log(key);
			// 注册所有自定义指令
			Vue.directive(key, directivesList[key]);
		});
	}
};

export default directives;
